<%@ page language="java" contentType="text/html; charset=UTF-8" pageEncoding="UTF-8" %>
<%@ taglib prefix="c" uri="http://java.sun.com/jsp/jstl/core" %>
<%@ taglib prefix="fmt" uri="http://java.sun.com/jsp/jstl/fmt" %>
<div class="modal-dialog ms-modal-dialog" id="reverse-order-edit-aviatino-user-info-dialog">
  <div class="modal-content">

    <div class="modal-header">
      <button type="button" class="close" data-dismiss="modal"><span aria-hidden="true">&times;</span><span
              class="sr-only">Close</span></button>
      <h4 class="modal-title">修改乘机人</h4>
    </div>

    <form class="form-horizontal ms-form" role="form" method="POST"
          action="${ctx.host}/reverse-orders/${orderId}/add-aviation-user-info" data-validate="true" >

      <div class="modal-body">

        <div class="form-group  ms-form-group">
          <label class="control-label col-xs-3">姓氏（拼音）：</label>
          <div class="col-xs-8 pull-left role-login-name">
            <input type="text" class="form-control" name="firstName" value="${aviationUserInfo.firstName}" data-validate="required"/>
          </div>
        </div>

        <div class="form-group  ms-form-group">
          <label class="control-label col-xs-3">名字（拼音）：</label>
          <div class="col-xs-8 pull-left role-login-name">
            <input type="text" class="form-control" name="lastName" value="${aviationUserInfo.lastName}" data-validate="required"/>
          </div>
        </div>

        <div class="form-group  ms-form-group">
          <label class="control-label col-xs-3">生日：</label>
          <div class="col-xs-8 pull-left role-login-name">
            <input type="text" class="form-control datetimepicker" name="birthday" value="${aviationUserInfo.birthday}" data-validate="required"/>

          </div>
        </div>

        <div class="form-group  ms-form-group">
          <label class="control-label col-xs-3">护照号：</label>
          <div class="col-xs-8 pull-left role-login-name">
            <input type="text" class="form-control" name="passportCode" value="${aviationUserInfo.passportCode}" data-validate="required"/>
          </div>
        </div>

        <div class="form-group  ms-form-group">
          <label class="control-label col-xs-3">护照到期时间：</label>
          <div class="col-xs-8 pull-left role-login-name">
            <input type="text" class="form-control datetimepicker" name="passportExpirationTime" value="<fmt:formatDate value="${aviationUserInfo.passportExpirationTime}" pattern="yyyy-MM-dd HH:mm:ss"></fmt:formatDate>" data-validate="required"/>

          </div>
        </div>

        <div class="form-group  ms-form-group">
          <label class="control-label col-xs-3">护照签发国：</label>
          <div class="col-xs-8 pull-left role-login-name">
            <input type="text" class="form-control" name="passportIssuingCountry" value="${aviationUserInfo.passportIssuingCountry}" data-validate="required"/>
          </div>
        </div>

        <div class="form-group  ms-form-group">
          <label class="control-label col-xs-3">性别：</label>
          <div class="col-xs-8 pull-left role-login-name">
            <select class="form-control select2" name="gender" data-validate="required">
              <option value="男" ${aviationUserInfo.gender == '男' ? 'selected' : ''}>男</option>
              <option value="女" ${aviationUserInfo.gender == '女' ? 'selected' : ''}>女</option>
            </select>
          </div>
        </div>

        <div class="form-group  ms-form-group">
          <label class="control-label col-xs-3">国籍：</label>
          <div class="col-xs-8 pull-left role-login-name">
            <input type="text" class="form-control" name="nationality" value="${aviationUserInfo.nationality}" data-validate="required"/>
          </div>
        </div>

        <div class="form-group  ms-form-group" style="min-height: 100px;">
          <label class="control-label col-xs-3">护照照片：</label>
          <div class="col-xs-8 upload-cover">
            <button type="button" id="pickCover" class="edit-btn" style="position: relative">
              <span class="glyphicon glyphicon-folder-open" aria-hidden="true"></span>&nbsp;&nbsp;选择文件
            </button>
            <div id="coverPreviewList" style="position: absolute;top: 0;width: 100px; height: 100px;">
              <img id="coverPreview" src=""  style="display: block; width: 100%;"/>
            </div>
            <input type="hidden" id="cover" name="passportPic"  data-validate="required"/>
            <label id="messageCover" class="control-label messageCover hide"></label>
          </div>
        </div>


      </div>

      <div class="modal-footer ms-modal-footer">
        <button type="submit" class="btn ms-btn btn-primary">确定</button>
        <button type="button" class="btn ms-btn ms-btn-gary" data-dismiss="modal">取消</button>
      </div>
    </form>

  </div>
</div>